We no longer need to create the signals here ... they come from the
authorOwen Taylor <otaylor@redhat.com>
Sun, 18 Nov 2001 00:10:57 +0000 (00:10 +0000)
committerOwen Taylor <otaylor@src.gnome.org>
Sun, 18 Nov 2001 00:10:57 +0000 (00:10 +0000)
Sat Nov 17 19:08:13 2001  Owen Taylor  <otaylor@redhat.com>

* tests/testtreeview.c (gtk_tree_model_types_get_type):
We no longer need to create the signals here ... they
come from the interface.

* gtk/maketypes.awk: Use GType, not GtkType in output.

* gtk/gtktypeutils.h: Mark virtually all of this
file deprecated.

* gtk/gtkcontainer.h: Deprecate gtk_container_foreach_full;
the only use of this function is the GtkArg using
GtkCallbackMarshal, since destroy notification is
silly here.

ChangeLog
ChangeLog.pre-2-0
ChangeLog.pre-2-10
ChangeLog.pre-2-2
ChangeLog.pre-2-4
ChangeLog.pre-2-6
ChangeLog.pre-2-8
gtk/gtkcontainer.h
gtk/gtktypeutils.h
gtk/maketypes.awk
tests/testtreeview.c

index e89d3ff5e9fcee32c439544c263397f8f8ae4024..5249d0e485d7f8f121b683f05a4de948cc41a2fd 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,19 @@
+Sat Nov 17 19:08:13 2001  Owen Taylor  <otaylor@redhat.com>
+
+       * tests/testtreeview.c (gtk_tree_model_types_get_type): 
+       We no longer need to create the signals here ... they
+       come from the interface.
+
+       * gtk/maketypes.awk: Use GType, not GtkType in output.
+
+       * gtk/gtktypeutils.h: Mark virtually all of this
+       file deprecated.
+
+       * gtk/gtkcontainer.h: Deprecate gtk_container_foreach_full;
+       the only use of this function is the GtkArg using
+       GtkCallbackMarshal, since destroy notification is
+       silly here.
+
 Sat Nov 17 18:26:45 2001  Owen Taylor  <otaylor@redhat.com>
 
        * gtk/Makefile.am gtk/gtkmarshal.list gtk/gtkmarshalers.list
index e89d3ff5e9fcee32c439544c263397f8f8ae4024..5249d0e485d7f8f121b683f05a4de948cc41a2fd 100644 (file)
@@ -1,3 +1,19 @@
+Sat Nov 17 19:08:13 2001  Owen Taylor  <otaylor@redhat.com>
+
+       * tests/testtreeview.c (gtk_tree_model_types_get_type): 
+       We no longer need to create the signals here ... they
+       come from the interface.
+
+       * gtk/maketypes.awk: Use GType, not GtkType in output.
+
+       * gtk/gtktypeutils.h: Mark virtually all of this
+       file deprecated.
+
+       * gtk/gtkcontainer.h: Deprecate gtk_container_foreach_full;
+       the only use of this function is the GtkArg using
+       GtkCallbackMarshal, since destroy notification is
+       silly here.
+
 Sat Nov 17 18:26:45 2001  Owen Taylor  <otaylor@redhat.com>
 
        * gtk/Makefile.am gtk/gtkmarshal.list gtk/gtkmarshalers.list
index e89d3ff5e9fcee32c439544c263397f8f8ae4024..5249d0e485d7f8f121b683f05a4de948cc41a2fd 100644 (file)
@@ -1,3 +1,19 @@
+Sat Nov 17 19:08:13 2001  Owen Taylor  <otaylor@redhat.com>
+
+       * tests/testtreeview.c (gtk_tree_model_types_get_type): 
+       We no longer need to create the signals here ... they
+       come from the interface.
+
+       * gtk/maketypes.awk: Use GType, not GtkType in output.
+
+       * gtk/gtktypeutils.h: Mark virtually all of this
+       file deprecated.
+
+       * gtk/gtkcontainer.h: Deprecate gtk_container_foreach_full;
+       the only use of this function is the GtkArg using
+       GtkCallbackMarshal, since destroy notification is
+       silly here.
+
 Sat Nov 17 18:26:45 2001  Owen Taylor  <otaylor@redhat.com>
 
        * gtk/Makefile.am gtk/gtkmarshal.list gtk/gtkmarshalers.list
index e89d3ff5e9fcee32c439544c263397f8f8ae4024..5249d0e485d7f8f121b683f05a4de948cc41a2fd 100644 (file)
@@ -1,3 +1,19 @@
+Sat Nov 17 19:08:13 2001  Owen Taylor  <otaylor@redhat.com>
+
+       * tests/testtreeview.c (gtk_tree_model_types_get_type): 
+       We no longer need to create the signals here ... they
+       come from the interface.
+
+       * gtk/maketypes.awk: Use GType, not GtkType in output.
+
+       * gtk/gtktypeutils.h: Mark virtually all of this
+       file deprecated.
+
+       * gtk/gtkcontainer.h: Deprecate gtk_container_foreach_full;
+       the only use of this function is the GtkArg using
+       GtkCallbackMarshal, since destroy notification is
+       silly here.
+
 Sat Nov 17 18:26:45 2001  Owen Taylor  <otaylor@redhat.com>
 
        * gtk/Makefile.am gtk/gtkmarshal.list gtk/gtkmarshalers.list
index e89d3ff5e9fcee32c439544c263397f8f8ae4024..5249d0e485d7f8f121b683f05a4de948cc41a2fd 100644 (file)
@@ -1,3 +1,19 @@
+Sat Nov 17 19:08:13 2001  Owen Taylor  <otaylor@redhat.com>
+
+       * tests/testtreeview.c (gtk_tree_model_types_get_type): 
+       We no longer need to create the signals here ... they
+       come from the interface.
+
+       * gtk/maketypes.awk: Use GType, not GtkType in output.
+
+       * gtk/gtktypeutils.h: Mark virtually all of this
+       file deprecated.
+
+       * gtk/gtkcontainer.h: Deprecate gtk_container_foreach_full;
+       the only use of this function is the GtkArg using
+       GtkCallbackMarshal, since destroy notification is
+       silly here.
+
 Sat Nov 17 18:26:45 2001  Owen Taylor  <otaylor@redhat.com>
 
        * gtk/Makefile.am gtk/gtkmarshal.list gtk/gtkmarshalers.list
index e89d3ff5e9fcee32c439544c263397f8f8ae4024..5249d0e485d7f8f121b683f05a4de948cc41a2fd 100644 (file)
@@ -1,3 +1,19 @@
+Sat Nov 17 19:08:13 2001  Owen Taylor  <otaylor@redhat.com>
+
+       * tests/testtreeview.c (gtk_tree_model_types_get_type): 
+       We no longer need to create the signals here ... they
+       come from the interface.
+
+       * gtk/maketypes.awk: Use GType, not GtkType in output.
+
+       * gtk/gtktypeutils.h: Mark virtually all of this
+       file deprecated.
+
+       * gtk/gtkcontainer.h: Deprecate gtk_container_foreach_full;
+       the only use of this function is the GtkArg using
+       GtkCallbackMarshal, since destroy notification is
+       silly here.
+
 Sat Nov 17 18:26:45 2001  Owen Taylor  <otaylor@redhat.com>
 
        * gtk/Makefile.am gtk/gtkmarshal.list gtk/gtkmarshalers.list
index e89d3ff5e9fcee32c439544c263397f8f8ae4024..5249d0e485d7f8f121b683f05a4de948cc41a2fd 100644 (file)
@@ -1,3 +1,19 @@
+Sat Nov 17 19:08:13 2001  Owen Taylor  <otaylor@redhat.com>
+
+       * tests/testtreeview.c (gtk_tree_model_types_get_type): 
+       We no longer need to create the signals here ... they
+       come from the interface.
+
+       * gtk/maketypes.awk: Use GType, not GtkType in output.
+
+       * gtk/gtktypeutils.h: Mark virtually all of this
+       file deprecated.
+
+       * gtk/gtkcontainer.h: Deprecate gtk_container_foreach_full;
+       the only use of this function is the GtkArg using
+       GtkCallbackMarshal, since destroy notification is
+       silly here.
+
 Sat Nov 17 18:26:45 2001  Owen Taylor  <otaylor@redhat.com>
 
        * gtk/Makefile.am gtk/gtkmarshal.list gtk/gtkmarshalers.list
index ae8095aee231b878717d6d8f4715636f94173cf5..3b06b78d4c32d69d6287c78e095e13092d715743 100644 (file)
@@ -118,11 +118,13 @@ void    gtk_container_check_resize       (GtkContainer     *container);
 void     gtk_container_foreach      (GtkContainer       *container,
                                     GtkCallback         callback,
                                     gpointer            callback_data);
+#ifndef GTK_DISABLE_DEPRECATED
 void     gtk_container_foreach_full (GtkContainer       *container,
                                     GtkCallback         callback,
                                     GtkCallbackMarshal  marshal,
                                     gpointer            callback_data,
                                     GtkDestroyNotify    notify);
+#endif /*  GTK_DISABLE_DEPRECATED */
 GList*   gtk_container_get_children     (GtkContainer       *container);
 
 #ifndef GTK_DISABLE_DEPRECATED
index 27eba03b9ab9d03ef571f6b882591280bcd589cb..494069864f9ae4f1d2c6d84abe10a771b11c68d3 100644 (file)
 #include <glib-object.h>
 
 
-#ifdef __cplusplus
-extern "C" {
-#endif /* __cplusplus */
+G_BEGIN_DECLS
 
+#ifndef GTK_DISABLE_DEPRECATED
 
 /* Fundamental Types
  * many of these are just aliases for GLib types to maintain
@@ -62,49 +61,49 @@ typedef enum        /*< skip >*/
   GTK_TYPE_POINTER     = G_TYPE_POINTER
 } GtkFundamentalType;
 
-
 /* --- type macros --- */
 #define GTK_CLASS_NAME(class)          (g_type_name (G_TYPE_FROM_CLASS (class)))
 #define GTK_CLASS_TYPE(class)          (G_TYPE_FROM_CLASS (class))
 #define GTK_TYPE_IS_OBJECT(type)       (g_type_is_a ((type), GTK_TYPE_OBJECT))
 
-
 /* outdated macros that really shouldn't e used anymore,
  * use the GLib type system instead
  */
-#ifndef GTK_DISABLE_DEPRECATED
 #define        GTK_TYPE_FUNDAMENTAL_LAST        (G_TYPE_LAST_RESERVED_FUNDAMENTAL - 1)
 #define        GTK_TYPE_FUNDAMENTAL_MAX         (G_TYPE_FUNDAMENTAL_MAX)
+
+#define        GTK_FUNDAMENTAL_TYPE    G_TYPE_FUNDAMENTAL
+#define GTK_STRUCT_OFFSET      G_STRUCT_OFFSET
+
 #endif /* GTK_DISABLE_DEPRECATED */
 
 /* glib macro wrappers (compatibility) */
-#define GTK_STRUCT_OFFSET      G_STRUCT_OFFSET
 #define        GTK_CHECK_CAST          G_TYPE_CHECK_INSTANCE_CAST
 #define        GTK_CHECK_CLASS_CAST    G_TYPE_CHECK_CLASS_CAST
 #define GTK_CHECK_GET_CLASS    G_TYPE_INSTANCE_GET_CLASS
 #define        GTK_CHECK_TYPE          G_TYPE_CHECK_INSTANCE_TYPE
 #define        GTK_CHECK_CLASS_TYPE    G_TYPE_CHECK_CLASS_TYPE
-#define        GTK_FUNDAMENTAL_TYPE    G_TYPE_FUNDAMENTAL
 
 /* glib type wrappers (compatibility) */
+
 typedef GType                  GtkType;
+
+#ifndef GTK_DISABLE_DEPRECATED
+
 typedef GTypeInstance          GtkTypeObject;
 typedef GTypeClass             GtkTypeClass;
 typedef GBaseInitFunc          GtkClassInitFunc;
 typedef GInstanceInitFunc      GtkObjectInitFunc;
 
+#endif /* GTK_DISABLE_DEPRECATED */
 
-#ifdef __cplusplus
-}
-#endif /* __cplusplus */
+G_END_DECLS
 
 /* Builtin Types
  */
 #include <gtk/gtktypebuiltins.h>
 
-#ifdef __cplusplus
-extern "C" {
-#endif /* __cplusplus */
+G_BEGIN_DECLS
 
 
 /* --- typedefs --- */
@@ -113,7 +112,6 @@ extern "C" {
  */
 typedef struct _GtkArg              GtkArg;
 typedef struct _GtkObject           GtkObject; /* object forward declaration */
-typedef struct _GtkTypeInfo         GtkTypeInfo;
 typedef gboolean (*GtkFunction)            (gpointer      data);
 typedef void (*GtkDestroyNotify)    (gpointer      data);
 typedef void (*GtkCallbackMarshal)  (GtkObject    *object,
@@ -121,9 +119,11 @@ typedef void (*GtkCallbackMarshal)  (GtkObject    *object,
                                     guint         n_args,
                                     GtkArg       *args);
 typedef void (*GtkSignalFunc)       (void);
-typedef GSignalCMarshaller          GtkSignalMarshaller;
 #define GTK_SIGNAL_FUNC(f)         ((GtkSignalFunc) (f))
 
+#ifndef GTK_DISABLE_DEPRECATED
+typedef struct _GtkTypeInfo         GtkTypeInfo;
+typedef GSignalCMarshaller          GtkSignalMarshaller;
 
 /* GtkArg, used to hold differently typed values */
 struct _GtkArg
@@ -217,15 +217,16 @@ struct _GtkTypeInfo
   gpointer              reserved_2;
   GtkClassInitFunc      base_class_init_func;
 };
-GtkType                gtk_type_unique (GtkType           parent_type,
-                                const GtkTypeInfo *gtkinfo);
-gpointer       gtk_type_class  (GtkType         type);
-gpointer       gtk_type_new    (GtkType         type);
 
+#endif /* GTK_DISABLE_DEPRECATED */
 
-/* deprecated, use g_type_init() instead */
-void           gtk_type_init   (GTypeDebugFlags debug_flags);
+gpointer       gtk_type_class  (GtkType         type);
 
+#ifndef GTK_DISABLE_DEPRECATED
+
+GtkType                gtk_type_unique (GtkType           parent_type,
+                                const GtkTypeInfo *gtkinfo);
+gpointer       gtk_type_new    (GtkType         type);
 
 /* --- compatibility defines --- */
 #define        gtk_type_name(type)              g_type_name (type)
@@ -233,6 +234,8 @@ void                gtk_type_init   (GTypeDebugFlags debug_flags);
 #define        gtk_type_parent(type)            g_type_parent (type)
 #define        gtk_type_is_a(type, is_a_type)   g_type_is_a ((type), (is_a_type))
 
+/* deprecated, use g_type_init() instead */
+void           gtk_type_init   (GTypeDebugFlags debug_flags);
 
 /* enum/flags compatibility functions, we strongly
  * recommend to use the glib enum/flags classes directly
@@ -259,10 +262,8 @@ GtkFlagValue*      gtk_type_flags_find_value       (GtkType         flags_type,
 /* urg */
 GTKTYPEUTILS_VAR GType GTK_TYPE_IDENTIFIER;
 
+#endif /* GTK_DISABLE_DEPRECATED */
 
-#ifdef __cplusplus
-}
-#endif /* __cplusplus */
-
+G_END_DECLS
 
 #endif /* __GTK_TYPE_UTILS_H__ */
index d0ab8b9f7b771ca90c1f9c739a245a944388e7f5..715e6cd95d3930720a3dd63f871e1f935450764c 100644 (file)
@@ -75,7 +75,7 @@ function generate (generate_what)
 {
   if (gen_macros)
     {
-      printf ("GTKTYPEBUILTINS_VAR GtkType %s;\n", type_macro);
+      printf ("GTKTYPEBUILTINS_VAR GType %s;\n", type_macro);
     }
   if (gen_entries)
     {
@@ -87,7 +87,7 @@ function generate (generate_what)
     }
   if (gen_vars)
     {
-      printf ("GTKTYPEBUILTINS_VAR GtkType %s = 0;\n", type_macro);
+      printf ("GTKTYPEBUILTINS_VAR GType %s = 0;\n", type_macro);
     }
 }
 
index 43bedfcfbb3205abfb27107594a0535d7e482b4c..5509537e4618187b1132fe8a74ced632bbaa1d89 100644 (file)
@@ -767,17 +767,7 @@ main (int    argc,
  * GtkTreeModelTypes
  */
 
-enum {
-  CHANGED,
-  INSERTED,
-  CHILD_TOGGLED,
-  DELETED,
-
-  LAST_SIGNAL
-};
-
 static void         gtk_tree_model_types_init                 (GtkTreeModelTypes      *model_types);
-static void         gtk_tree_model_types_class_init           (GtkTreeModelTypesClass *class);
 static void         gtk_tree_model_types_tree_model_init      (GtkTreeModelIface   *iface);
 static gint         gtk_real_model_types_get_n_columns   (GtkTreeModel        *tree_model);
 static GType        gtk_real_model_types_get_column_type (GtkTreeModel        *tree_model,
@@ -806,9 +796,6 @@ static gboolean     gtk_real_model_types_iter_parent     (GtkTreeModel        *t
                                                           GtkTreeIter         *child);
 
 
-static guint model_types_signals[LAST_SIGNAL] = { 0 };
-
-
 GtkType
 gtk_tree_model_types_get_type (void)
 {
@@ -821,7 +808,7 @@ gtk_tree_model_types_get_type (void)
         sizeof (GtkTreeModelTypesClass),
        NULL,           /* base_init */
        NULL,           /* base_finalize */
-        (GClassInitFunc) gtk_tree_model_types_class_init,
+        NULL,           /* class_init */
        NULL,           /* class_finalize */
        NULL,           /* class_data */
         sizeof (GtkTreeModelTypes),
@@ -855,54 +842,6 @@ gtk_tree_model_types_new (void)
   return retval;
 }
 
-static void
-gtk_tree_model_types_class_init (GtkTreeModelTypesClass *class)
-{
-  GObjectClass *object_class;
-
-  object_class = (GObjectClass*) class;
-
-  model_types_signals[CHANGED] =
-    g_signal_new ("changed",
-                  GTK_CLASS_TYPE (object_class),
-                  G_SIGNAL_RUN_FIRST,
-                  GTK_SIGNAL_OFFSET (GtkTreeModelTypesClass, changed),
-                  NULL, NULL,
-                  gtk_marshal_VOID__BOXED_BOXED,
-                  G_TYPE_NONE, 2,
-                  G_TYPE_POINTER,
-                  G_TYPE_POINTER);
-  model_types_signals[INSERTED] =
-    g_signal_new ("inserted",
-                  GTK_CLASS_TYPE (object_class),
-                  G_SIGNAL_RUN_FIRST,
-                  GTK_SIGNAL_OFFSET (GtkTreeModelTypesClass, inserted),
-                  NULL, NULL,
-                  gtk_marshal_VOID__BOXED_BOXED,
-                  G_TYPE_NONE, 2,
-                  G_TYPE_POINTER,
-                  G_TYPE_POINTER);
-  model_types_signals[CHILD_TOGGLED] =
-    g_signal_new ("child_toggled",
-                  GTK_CLASS_TYPE (object_class),
-                  G_SIGNAL_RUN_FIRST,
-                  GTK_SIGNAL_OFFSET (GtkTreeModelTypesClass, child_toggled),
-                  NULL, NULL,
-                  gtk_marshal_VOID__BOXED_BOXED,
-                  G_TYPE_NONE, 2,
-                  G_TYPE_POINTER,
-                  G_TYPE_POINTER);
-  model_types_signals[DELETED] =
-    g_signal_new ("deleted",
-                  GTK_CLASS_TYPE (object_class),
-                  G_SIGNAL_RUN_FIRST,
-                  GTK_SIGNAL_OFFSET (GtkTreeModelTypesClass, deleted),
-                  NULL, NULL,
-                  gtk_marshal_VOID__BOXED,
-                  G_TYPE_NONE, 1,
-                  G_TYPE_POINTER);
-}
-
 static void
 gtk_tree_model_types_tree_model_init (GtkTreeModelIface *iface)
 {